<template>
  <el-card class="app-container">
    <c-u-r-d-table :option="option"/>
  </el-card>
</template>

<script>

import ColumnType from '@/framework/constant/ColumnType'
import {commentPageApi} from '@/feature/cms/infra/api/commentPageApi'
import CURDTable from '@/framework/components/table/CURDTable'
import OnlineStatusEnum from "@/framework/constant/auditEnum";
export default {
  components: {CURDTable},
  data() {
    return {
      option: {
        requestApi: commentPageApi,
        dialogWidth: '5600px',
        showSelection: false,
        columns: [
          {
            label: '昵称',
            width: 120,
            prop: 'nickName',
            span: 24,
            required: true,
            searchable: true
          },
          {
            label: '头像',
            span: 24,
            width: 80,
            prop: 'headImg',
            required: true,
            type: ColumnType.IMAGE
          },
          {
            label: '类型',
            width: 100,
            span: 12,
            prop: 'businessTypeLabel'
          },
          {
            label: '状态',
            span: 12,
            width: 100,
            searchable: true,
            type: ColumnType.RADIO,
            hiddenInForm: true,
            options: OnlineStatusEnum,
            prop: 'audit'
          },
          {
            label: '手机号',
            width: 120,
            prop: 'telephone',
            span: 20,
            required: true,
            searchable: true
          },
          {
            label: '评论内容',
            span: 24,
            width: 480,
            prop: 'comment',
            required: true,
            searchable: true,
            type: ColumnType.TEXTAREA
          },
          {
            label: '创建时间',
            type: ColumnType.DATETIME,
            hiddenInForm: true,
            prop: 'gmtCreate'
          },
          {
            label: '修改时间',
            type: ColumnType.DATETIME,
            hiddenInForm: true,
            prop: 'gmtModified'
          },
        ]
      }
    }
  },
  methods: {}
}
</script>

